Xbasic

UI_SHAPE_OVAL Function

Syntax

V UI_SHAPE_OVAL(C shape,N x,N y,N width,N height[,C shape_operation])

Arguments

shape

The name of a new or existing shape.

x

The horizontal coordinate of the upper left corner of the oval. Larger values move right.

y

The vertical coordinate of the upper left corner of the oval. Larger values move down.

width

The width of the oval.

height

The height of the oval.

shape_operation

Shape_Operation Optional. Default = erase previous shape. An indication of how to combine the shape with other shapes.

"and" = show only the intersection of the oval and any other shapes.
"or" = show both the union of the oval and any other shapes.
"xor" = show both the oval and any other shapes, but do not show their intersection.

Description

UI_SHAPE_OVAL() creates an oval shape in memory that may be combined with other shapes.

images/GR_clip_shape.gif
ui_bitmap_load("stone", file.to_blob("C:\WINDOWS\Greenstone.bmp"))
ui_bitmap_create("test", 4, 2)
ui_shape_oval("oval", 0, 0, 4, 2)
ui_bitmap_draw("test", <<%code%
inner_rect(0, 0, 4, 2)
clip_shape("oval", 0, 0)
bitmap("stone", 0, 0, 4, 2)
%code%)
ui_dlg_box("", "{image=test}")

Limitations

This function is only used in the Code sections of UI_BITMAP_DRAW(), UI_SCREEN_DRAW(), and UI_PRINTER_DRAW().

See Also